.class public Lcom/adview/adapters/LmMobAdapter;
.super Lcom/adview/adapters/AdViewAdapter;
.source "LmMobAdapter.java"

# interfaces
.implements Lcom/lmmob/ad/sdk/LmMobAdRequestListener;


# instance fields
.field private adView:Lcom/lmmob/ad/sdk/LmMobAdView;


# direct methods
.method public constructor <init>(Lcom/adview/AdViewLayout;Lcom/adview/obj/Ration;)V
    .locals 0
    .parameter "adViewLayout"
    .parameter "ration"

    .prologue
    .line 24
    invoke-direct {p0, p1, p2}, Lcom/adview/adapters/AdViewAdapter;-><init>(Lcom/adview/AdViewLayout;Lcom/adview/obj/Ration;)V

    .line 26
    return-void
.end method


# virtual methods
.method public adRecieveFailure()V
    .locals 3

    .prologue
    .line 57
    invoke-static {}, Lcom/adview/AdViewTargeting;->getRunMode()Lcom/adview/AdViewTargeting$RunMode;

    move-result-object v1

    sget-object v2, Lcom/adview/AdViewTargeting$RunMode;->TEST:Lcom/adview/AdViewTargeting$RunMode;

    if-ne v1, v2, :cond_0

    .line 58
    const-string v1, "AdView SDK v1.7.0"

    const-string v2, "LmMob failure"

    invoke-static {v1, v2}, Landroid/util/Log;->d(Ljava/lang/String;Ljava/lang/String;)I

    .line 60
    :cond_0
    iget-object v1, p0, Lcom/adview/adapters/LmMobAdapter;->adView:Lcom/lmmob/ad/sdk/LmMobAdView;

    const/4 v2, 0x0

    invoke-virtual {v1, v2}, Lcom/lmmob/ad/sdk/LmMobAdView;->setAdRequestListener(Lcom/lmmob/ad/sdk/LmMobAdRequestListener;)V

    .line 62
    iget-object v1, p0, Lcom/adview/adapters/LmMobAdapter;->adViewLayoutReference:Ljava/lang/ref/WeakReference;

    invoke-virtual {v1}, Ljava/lang/ref/WeakReference;->get()Ljava/lang/Object;

    move-result-object v0

    check-cast v0, Lcom/adview/AdViewLayout;

    .line 63
    .local v0, adViewLayout:Lcom/adview/AdViewLayout;
    if-nez v0, :cond_1

    .line 69
    :goto_0
    return-void

    .line 66
    :cond_1
    iget-object v1, v0, Lcom/adview/AdViewLayout;->adViewManager:Lcom/adview/AdViewManager;

    invoke-virtual {v1}, Lcom/adview/AdViewManager;->resetRollover_pri()V

    .line 67
    invoke-virtual {v0}, Lcom/adview/AdViewLayout;->rotateThreadedPri()V

    goto :goto_0
.end method

.method public adRecieveSuccess()V
    .locals 3

    .prologue
    .line 75
    invoke-static {}, Lcom/adview/AdViewTargeting;->getRunMode()Lcom/adview/AdViewTargeting$RunMode;

    move-result-object v1

    sget-object v2, Lcom/adview/AdViewTargeting$RunMode;->TEST:Lcom/adview/AdViewTargeting$RunMode;

    if-ne v1, v2, :cond_0

    .line 76
    const-string v1, "AdView SDK v1.7.0"

    const-string v2, "LmMob success"

    invoke-static {v1, v2}, Landroid/util/Log;->d(Ljava/lang/String;Ljava/lang/String;)I

    .line 78
    :cond_0
    iget-object v1, p0, Lcom/adview/adapters/LmMobAdapter;->adView:Lcom/lmmob/ad/sdk/LmMobAdView;

    const/4 v2, 0x0

    invoke-virtual {v1, v2}, Lcom/lmmob/ad/sdk/LmMobAdView;->setAdRequestListener(Lcom/lmmob/ad/sdk/LmMobAdRequestListener;)V

    .line 80
    iget-object v1, p0, Lcom/adview/adapters/LmMobAdapter;->adViewLayoutReference:Ljava/lang/ref/WeakReference;

    invoke-virtual {v1}, Ljava/lang/ref/WeakReference;->get()Ljava/lang/Object;

    move-result-object v0

    check-cast v0, Lcom/adview/AdViewLayout;

    .line 81
    .local v0, adViewLayout:Lcom/adview/AdViewLayout;
    if-nez v0, :cond_1

    .line 89
    :goto_0
    return-void

    .line 85
    :cond_1
    iget-object v1, v0, Lcom/adview/AdViewLayout;->adViewManager:Lcom/adview/AdViewManager;

    invoke-virtual {v1}, Lcom/adview/AdViewManager;->resetRollover()V

    .line 87
    invoke-virtual {v0}, Lcom/adview/AdViewLayout;->rotateThreadedDelayed()V

    goto :goto_0
.end method

.method public handle()V
    .locals 5

    .prologue
    .line 32
    invoke-static {}, Lcom/adview/AdViewTargeting;->getRunMode()Lcom/adview/AdViewTargeting$RunMode;

    move-result-object v2

    sget-object v3, Lcom/adview/AdViewTargeting$RunMode;->TEST:Lcom/adview/AdViewTargeting$RunMode;

    if-ne v2, v3, :cond_0

    .line 33
    const-string v2, "AdView SDK v1.7.0"

    const-string v3, "Into LmMob"

    invoke-static {v2, v3}, Landroid/util/Log;->d(Ljava/lang/String;Ljava/lang/String;)I

    .line 34
    :cond_0
    iget-object v2, p0, Lcom/adview/adapters/LmMobAdapter;->adViewLayoutReference:Ljava/lang/ref/WeakReference;

    invoke-virtual {v2}, Ljava/lang/ref/WeakReference;->get()Ljava/lang/Object;

    move-result-object v1

    check-cast v1, Lcom/adview/AdViewLayout;

    .line 35
    .local v1, adViewLayout:Lcom/adview/AdViewLayout;
    if-nez v1, :cond_2

    .line 51
    :cond_1
    :goto_0
    return-void

    .line 39
    :cond_2
    iget-object v2, v1, Lcom/adview/AdViewLayout;->activityReference:Ljava/lang/ref/WeakReference;

    invoke-virtual {v2}, Ljava/lang/ref/WeakReference;->get()Ljava/lang/Object;

    move-result-object v0

    check-cast v0, Landroid/app/Activity;

    .line 40
    .local v0, activity:Landroid/app/Activity;
    if-eqz v0, :cond_1

    .line 46
    iget-object v2, p0, Lcom/adview/adapters/LmMobAdapter;->ration:Lcom/adview/obj/Ration;

    iget-object v2, v2, Lcom/adview/obj/Ration;->key:Ljava/lang/String;

    invoke-static {v2}, Lcom/lmmob/ad/sdk/LmMobEngine;->init(Ljava/lang/String;)V

    .line 47
    new-instance v2, Lcom/lmmob/ad/sdk/LmMobAdView;

    invoke-direct {v2, v0}, Lcom/lmmob/ad/sdk/LmMobAdView;-><init>(Landroid/content/Context;)V

    iput-object v2, p0, Lcom/adview/adapters/LmMobAdapter;->adView:Lcom/lmmob/ad/sdk/LmMobAdView;

    .line 48
    iget-object v2, p0, Lcom/adview/adapters/LmMobAdapter;->adView:Lcom/lmmob/ad/sdk/LmMobAdView;

    invoke-virtual {v2, p0}, Lcom/lmmob/ad/sdk/LmMobAdView;->setAdRequestListener(Lcom/lmmob/ad/sdk/LmMobAdRequestListener;)V

    .line 49
    iget-object v2, v1, Lcom/adview/AdViewLayout;->handler:Landroid/os/Handler;

    new-instance v3, Lcom/adview/AdViewLayout$ViewAdRunnable;

    iget-object v4, p0, Lcom/adview/adapters/LmMobAdapter;->adView:Lcom/lmmob/ad/sdk/LmMobAdView;

    invoke-direct {v3, v1, v4}, Lcom/adview/AdViewLayout$ViewAdRunnable;-><init>(Lcom/adview/AdViewLayout;Landroid/view/ViewGroup;)V

    invoke-virtual {v2, v3}, Landroid/os/Handler;->post(Ljava/lang/Runnable;)Z

    goto :goto_0
.end method

.method public setAdSpecWidth()I
    .locals 1

    .prologue
    .line 93
    const/4 v0, 0x0

    return v0
.end method
